/*
 * Copyright (c) Huawei Technologies Co., Ltd. 2021-2025. All rights reserved.
 *
 */

import { SdkVersionEnum } from '../version/sdk-version-enum.js';
import { SdkVersion } from '../version/sdk-version.js';
import { SdkInfo } from './sdk-info.js';

const NO_IMPL_EXCEPTION = 'No impl exception';

export class DefaultSdk implements SdkInfo {
  hasRollUpPluginInEtsLoader = true;

  hasRollUpPluginInJsLoader = true;

  isOhos = false;

  sdkDir = '';

  async setup(): Promise<void> {
    // no action
  }

  checkAotFixedSdkVersion(): boolean {
    const fixedAotVersion = SdkVersionEnum.FIXED_AOT_OHOS;
    const etsSdkVersion: string = this.getEtsComponentVersion();
    if (etsSdkVersion === '') {
      return true;
    }
    const curAotVersion = new SdkVersion(etsSdkVersion);
    return curAotVersion.isHigherThan(fixedAotVersion);
  }

  getAppSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getInsightIntentSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getArkDataSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getUtdSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getArkUIXSdkDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getArkVersion(compatibleSdkVersion: number, compatibleSdkVersionStage?: string): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getCmakeTool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getEtsComponentReleaseType(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getEtsComponentVersion(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHosToolchainsDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getEtsLoader(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getFormSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHapSignToolV2(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHapTobin(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHmsArkDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHmsNativeDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHmsToolchainFile(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHmsBiShengToolchainFile(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHosModuleSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHosResTool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getJsLoader(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getLiteSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getModuleSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getNativeNinjaTool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getNativeToolchain(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getOhosJar(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getPackageTool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getPageSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getStartWindowSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSystemThemeSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getRouterMapSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getShortcutsJsonSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getAppStartupSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHspStartupSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHarStartupSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSysCapSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getPacSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getReleaseType(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getRestool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getRichSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkEtsDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkJsDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkNativeDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkToolchainsDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkLlvmStrip(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkLlvmReadElf(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkVersion(): number {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHosToolchainsLibDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getLibimageTranscoderShared(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getPreviewerCommonBinDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getPreviewerPermissionNames(): string[] {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getPreviewerUserGrant(): string[] {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  allowSdkPermission(): boolean {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSignDir(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHosSignTool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSysCapFileInEts(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSysCapFileInJs(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSysCapTool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getToolchainsComponentVersion(): string | undefined {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHosToolchainsComponentVersion(): string | undefined {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getVerifySignConfigTool(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  isPreviewCompileResourceIncrement(isHarmonyOS: boolean): any {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  requireUISyntax(): boolean {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  supportOhpmProject(isHarmonyOS: boolean): any {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  supportHapSignToolApiCall(isHarmonyOS: boolean): boolean {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getSdkApi(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getBasePath(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getAppConfigurationSchema(): string {
    throw new Error(NO_IMPL_EXCEPTION);
  }


  getDriverBuild(): string{
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getArkUIPlugin(): string{
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getArkUIMemoPlugin(): string{
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getArkUIInteropPlugin(): string{
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getRunEs2AbcStandalone(): string{
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getRunDeclgenStandalone(): string{
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getHmsEtsV2ApiPaths(): string[] {
    throw new Error(NO_IMPL_EXCEPTION);
  }

  getOpenHarmonyEtsV2ApiPaths(): string[] {
    throw new Error(NO_IMPL_EXCEPTION);
  }
}
